# -*- coding:utf-8 -*-

from dbbasic import dbMgr

def update(id, value):
	with dbMgr() as cursor:
		cursor.execute('update work set value=? where id=?', (value, id))
		
def get(id):
	with dbMgr() as cursor:
		cursor.execute('select * from work where id=?' , (id,))
		value = cursor.fetchone()
		if value == None:
			return None
		return value[1]